﻿using Abp.Dependency;
using Abp.Threading.BackgroundWorkers;
using DHJ.Cost.InitData;
using Hangfire;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DHJ.Cost.CostAccounting.Job;

namespace DHJ.Cost.Web.Recurring
{
    public class HangfireRecurringWorker : BackgroundWorkerBase, ISingletonDependency
    {
        public override void Start()
        {
            //        RecurringJob.AddOrUpdate<BatchManHourJob>(
            //            job => job.Execute(new Abp.UserIdentifier(1, 2)),
            //            Cron.Monthly(21), TimeZoneInfo.Local);

            //        RecurringJob.AddOrUpdate<CostAnalysisJob>(
            //            job => job.Execute(0),
            //            Cron.Daily, TimeZoneInfo.Local);


            //        RecurringJob.AddOrUpdate<AnnualCostAnalysisJob>(
            //            job => job.Execute(0),
            //            Cron.Monthly(22), TimeZoneInfo.Local);


            //        RecurringJob.AddOrUpdate<WorkshopCostAnalysisJob>(
            //            job => job.Execute(0),
            //            Cron.Monthly(22), TimeZoneInfo.Local);

            //        RecurringJob.AddOrUpdate<BatchCostJob>(
            //job => job.Execute(0),
            //Cron.Daily(0), TimeZoneInfo.Local); 
        }
    }
}